# Homepage Dynamic Config Guide

The homepage uses a dynamic config that allows us to update content without
changing code. This includes:

- Hero section text and animations
- Featured songs
- Featured videos
- Campaign-specific content

## How to Update Content

Access the dynamic config here:
https://console.statsig.com/64RBMXCoSmsTc9oTU9ghAk/dynamic_configs/splash-page-campaign-config

### 1. Campaign Config Structure

The configuration follows this structure:

```json
{
  "default": {
    "hero": {
      "typingText": [
        {
          "text": "This Father's Day, skip the mug. Make him a masterpiece",
          "className": "max-w-[1020px] h-[150px] transition-all duration-300",
          "once": true
        },
        {
          "text": "Make him a rock song about his funny style",
          "className": "max-w-[854px] h-[150px] transition-all duration-300"
        }
        // ... more typing text options
      ],
      "subHeading": "Start with a simple prompt or dive into our pro editing tools..."
    },
    "featuredSongs": {
      "playlist_id": "your-playlist-id",
      "heading": "Mind blowing song quality",
      "subHeading": "Whether you have a melody in your head..."
    },
    "featuredVideos": {
      "heading": "Explore and get inspired",
      "subHeading": "Step into a world where music is at your fingertips...",
      "videoMediaUrls": [
        {
          "id": "1",
          "videoUrl": "https://cdn1.suno.ai/Abby.mp4",
          "posterUrl": "https://cdn1.suno.ai/Abby%2BThumbnail.png",
          "title": "abby",
          "artistName": "Suno",
          "playCount": 0,
          "likeCount": 0
        }
        // ... more videos
      ]
    }
  }
}
```

### 2. How to Use Campaign IDs

- Create a new campaign by adding a new key to the configuration (e.g.,
  "fathers2025")
- Type in `/home?campaign_id=fathers2025` or `/home/c/fathers2025` to access the
  campaign
- If no campaign_id is provided, the "default" configuration is used

### 3. Testing Your Changes

1. Create your campaign configuration
2. Add `?campaign_id=your_campaign_id` to the homepage URL
3. Test on different devices and screen sizes
4. Verify all media loads correctly (you can modify the url to test with a
   playlist on staging but make sure that your final playlist urlId is public)
5. Check that animations work smoothly

### 6. Common Issues

- If content doesn't update, check the campaign_id in the URL
- If images don't load, verify the aws URL encoding
- If videos don't play, check the video URL and format
